package com.sms.gui.actions;

import java.awt.event.ActionEvent;

import javax.swing.AbstractAction;
import javax.swing.JFrame;

import com.sms.gui.SettingsDialog;
import com.sms.util.ResourcesHandler;

public class SettingsAction extends AbstractAction {

    private static final long serialVersionUID = 1L;
    private JFrame frame;

    public SettingsAction(JFrame f) {
        super();
        frame = f;
        putValue(AbstractAction.NAME, "Settings");
        putValue(AbstractAction.SMALL_ICON, ResourcesHandler.CONFIG_IMG);
    }

    @Override
    public void actionPerformed(ActionEvent e) {
        new SettingsDialog(frame).setVisible(true);
    }
}
